package com.night.icm.persistence.base.repository;

import com.night.icm.persistence.base.entity.Course;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

/**
 * CourseRepository
 *
 * @author Liao ZhiYong
 * @date 2020/2/5
 */
@Repository
public interface CourseRepository extends JpaRepository<Course, Long>, JpaSpecificationExecutor<Course> {

    /**
     * 根据code查找课程
     *
     * @param code code
     */
    Course findByCode(String code);
}
